<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">

<title>class Bundler::CLI::Doctor - bundler: Ruby Standard Library Documentation</title>


<script src="../../js/navigation.js" defer></script>
<script src="../../js/search.js" defer></script>
<script src="../../js/search_index.js" defer></script>
<script src="../../js/searcher.js" defer></script>
<script src="../../js/darkfish.js" defer></script>

<script src="../../js/jquery-3.2.0.min.js"></script>

<script src="../../js/vue.min.js"></script>
<script src="../../js/js.cookie.min.js"></script>

<link href="../../css/fonts.css" rel="stylesheet">
<link id='rdoccss' href="../../css/rdoc.css" rel="stylesheet">
<link href="../../css/carbon17.css" rel="stylesheet">

<script type="text/javascript">
  var rdoc_rel_prefix = "../../";
  var index_rel_prefix = "../../";
  var darkModeCsseHref = "../../css/rdoc-dm.css"
  var defaultModeCssHref = "../../css/rdoc.css"
  // var cssDarkmode = Cookies.get('darkmode');
  
  if( Cookies.get("darkmode") == "true") {
	$('#rdoccss').attr("href", darkModeCsseHref);
}

//  https://cssdeck.com/blog/simple-jquery-stylesheet-switcher/

document.write('<style type="text/css">body{display:none}</style>');

</script>


</head>
<body id="top" role="document" class="class">
  <!-- this is class.html -->

  <div id='actionbar' >
    <div class='wrapper mdiv'>
      <ul class='grids g0'></ul>
    </div> 
    <!-- VERSION HEADER for 3.3.0.preview2 NOT FOUND -->
  </div> <!-- end action bar -->

  <div class='wrapper hdiv'>

    


    <nav id='vapp' role="navigation">
    <div id="project-navigation">
      <div id="home-section" role="region" title="Quick navigation" class="nav-section">
  <h2><a href="../../index.html" rel="home">Home</a></h2>

  <div id="table-of-contents-navigation"  >
    <a href="../../table_of_contents.html#pages">Pages</a>
    <a href="../../table_of_contents.html#classes">Classes</a>
    <a href="../../table_of_contents.html#methods">Methods</a>
  </div>
</div>

      <div id="search-section" role="search" class="project-section initially-hidden">
  <form action="#" method="get" accept-charset="utf-8">
    <div id="search-field-wrapper">
      <input id="search-field" role="combobox" aria-label="Search"
             aria-autocomplete="list" aria-controls="search-results"
             type="text" name="search" placeholder="Search" spellcheck="false"
             title="Type to search, Up and Down to navigate, Enter to load">
    </div>

    <ul id="search-results" aria-label="Search Results"
        aria-busy="false" aria-expanded="false"
        aria-atomic="false" class="initially-hidden"></ul>
  </form>
</div>

    </div>


    

    <button id='toggleThing' @click="toggleNav()" >Show/hide navigation</button>
    <div :class="isOpen ? 'block' : 'hidden' " id='toggleMe'>
      <div id="class-metadata">
        
        
<div id="parent-class-section" class="nav-section">
  <h3>Parent</h3>

  <p class="link"><a href="../../Object.html">Object</a>
</div>

        
        
        
<!-- Method Quickref -->
<div id="method-list-section" class="nav-section">
  <h3>Methods</h3>

  <ul class="link-list" role="directory">
    <li ><a href="#method-c-new">::new</a>
    <li ><a href="#method-i-bundles_for_gem">#bundles_for_gem</a>
    <li ><a href="#method-i-check-21">#check!</a>
    <li ><a href="#method-i-check_home_permissions">#check_home_permissions</a>
    <li ><a href="#method-i-dylibs">#dylibs</a>
    <li ><a href="#method-i-dylibs_darwin">#dylibs_darwin</a>
    <li ><a href="#method-i-dylibs_ldd">#dylibs_ldd</a>
    <li ><a href="#method-i-ldd_available-3F">#ldd_available?</a>
    <li ><a href="#method-i-otool_available-3F">#otool_available?</a>
    <li ><a href="#method-i-run">#run</a>
  </ul>
</div>

      </div>
     </div>
    </nav>


    <div id='extraz'><div class='adzbox-index'  >
      
     </div>         
    </div>

    <main role="main" aria-labelledby="class-Bundler::CLI::Doctor">
    <h1 id="class-Bundler::CLI::Doctor" class="class">
      class Bundler::CLI::Doctor
    </h1>

    <section class="description">
    
    </section>

      <section id="5Buntitled-5D" class="documentation-section">


      <section class="constants-list">
      <header>
      <h3>Constants</h3>
      </header>
      <dl>
          <dt id="DARWIN_REGEX">DARWIN_REGEX
          <dd>
          <dt id="LDD_REGEX">LDD_REGEX
          <dd>
        </dl>
        </section>

        <section class="attribute-method-details" class="method-section">
        <header>
        <h3>Attributes</h3>
        </header>

          <div id="attribute-i-options" class="method-detail">
            <div class="method-heading attribute-method-heading">
              <span class="method-name">options</span><span
                class="attribute-access-type">[R]</span>
            </div>

            <div class="method-description">
              
              </div>
            </div>
            </section>


                <section id="public-class-5Buntitled-5D-method-details" class="method-section">
                <header>
                <h3>Public Class Methods</h3>
                </header>

                  <div id="method-c-new" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">new</span><span
                                class="method-args">(options)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="new-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 14</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">initialize</span>(<span class="ruby-identifier">options</span>)
  <span class="ruby-ivar">@options</span> = <span class="ruby-identifier">options</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                          </section>

                <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
                <header>
                <h3>Public Instance Methods</h3>
                </header>

                  <div id="method-i-bundles_for_gem" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">bundles_for_gem</span><span
                                class="method-args">(spec)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="bundles_for_gem-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 56</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">bundles_for_gem</span>(<span class="ruby-identifier">spec</span>)
  <span class="ruby-constant">Dir</span>.<span class="ruby-identifier">glob</span>(<span class="ruby-node">&quot;#{spec.full_gem_path}/**/*.bundle&quot;</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-check-21" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">check!</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="check-21-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 60</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">check!</span>
  <span class="ruby-identifier">require_relative</span> <span class="ruby-string">&quot;check&quot;</span>
  <span class="ruby-constant">Bundler</span><span class="ruby-operator">::</span><span class="ruby-constant">CLI</span><span class="ruby-operator">::</span><span class="ruby-constant">Check</span>.<span class="ruby-identifier">new</span>({}).<span class="ruby-identifier">run</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-dylibs" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">dylibs</span><span
                                class="method-args">(path)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="dylibs-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 42</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">dylibs</span>(<span class="ruby-identifier">path</span>)
  <span class="ruby-keyword">case</span> <span class="ruby-constant">RbConfig</span><span class="ruby-operator">::</span><span class="ruby-constant">CONFIG</span>[<span class="ruby-string">&quot;host_os&quot;</span>]
  <span class="ruby-keyword">when</span> <span class="ruby-regexp">/darwin/</span>
    <span class="ruby-keyword">return</span> [] <span class="ruby-keyword">unless</span> <span class="ruby-identifier">otool_available?</span>
    <span class="ruby-identifier">dylibs_darwin</span>(<span class="ruby-identifier">path</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-regexp">/(linux|solaris|bsd)/</span>
    <span class="ruby-keyword">return</span> [] <span class="ruby-keyword">unless</span> <span class="ruby-identifier">ldd_available?</span>
    <span class="ruby-identifier">dylibs_ldd</span>(<span class="ruby-identifier">path</span>)
  <span class="ruby-keyword">else</span> <span class="ruby-comment"># Windows, etc.</span>
    <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">ui</span>.<span class="ruby-identifier">warn</span>(<span class="ruby-string">&quot;Dynamic library check not supported on this platform.&quot;</span>)
    []
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-dylibs_darwin" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">dylibs_darwin</span><span
                                class="method-args">(path)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="dylibs_darwin-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 26</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">dylibs_darwin</span>(<span class="ruby-identifier">path</span>)
  <span class="ruby-identifier">output</span> = <span class="ruby-node">`/usr/bin/otool -L #{path.shellescape}`</span>.<span class="ruby-identifier">chomp</span>
  <span class="ruby-identifier">dylibs</span> = <span class="ruby-identifier">output</span>.<span class="ruby-identifier">split</span>(<span class="ruby-string">&quot;\n&quot;</span>)[<span class="ruby-value">1</span><span class="ruby-operator">..</span><span class="ruby-value">-1</span>].<span class="ruby-identifier">map</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">l</span><span class="ruby-operator">|</span> <span class="ruby-identifier">l</span>.<span class="ruby-identifier">match</span>(<span class="ruby-constant">DARWIN_REGEX</span>).<span class="ruby-identifier">captures</span>[<span class="ruby-value">0</span>] }.<span class="ruby-identifier">uniq</span>
  <span class="ruby-comment"># ignore @rpath and friends</span>
  <span class="ruby-identifier">dylibs</span>.<span class="ruby-identifier">reject</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">dylib</span><span class="ruby-operator">|</span> <span class="ruby-identifier">dylib</span>.<span class="ruby-identifier">start_with?</span> <span class="ruby-string">&quot;@&quot;</span> }
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-dylibs_ldd" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">dylibs_ldd</span><span
                                class="method-args">(path)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="dylibs_ldd-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 33</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">dylibs_ldd</span>(<span class="ruby-identifier">path</span>)
  <span class="ruby-identifier">output</span> = <span class="ruby-node">`/usr/bin/ldd #{path.shellescape}`</span>.<span class="ruby-identifier">chomp</span>
  <span class="ruby-identifier">output</span>.<span class="ruby-identifier">split</span>(<span class="ruby-string">&quot;\n&quot;</span>).<span class="ruby-identifier">map</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">l</span><span class="ruby-operator">|</span>
    <span class="ruby-identifier">match</span> = <span class="ruby-identifier">l</span>.<span class="ruby-identifier">match</span>(<span class="ruby-constant">LDD_REGEX</span>)
    <span class="ruby-keyword">next</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">match</span>.<span class="ruby-identifier">nil?</span>
    <span class="ruby-identifier">match</span>.<span class="ruby-identifier">captures</span>[<span class="ruby-value">0</span>]
  <span class="ruby-keyword">end</span>.<span class="ruby-identifier">compact</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-ldd_available-3F" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">ldd_available?</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="ldd_available-3F-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 22</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">ldd_available?</span>
  <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">which</span>(<span class="ruby-string">&quot;ldd&quot;</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-otool_available-3F" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">otool_available?</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="otool_available-3F-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 18</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">otool_available?</span>
  <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">which</span>(<span class="ruby-string">&quot;otool&quot;</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-run" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">run</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="run-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 65</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">run</span>
  <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">ui</span>.<span class="ruby-identifier">level</span> = <span class="ruby-string">&quot;warn&quot;</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">options</span>[<span class="ruby-value">:quiet</span>]
  <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">settings</span>.<span class="ruby-identifier">validate!</span>
  <span class="ruby-identifier">check!</span>

  <span class="ruby-identifier">definition</span> = <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">definition</span>
  <span class="ruby-identifier">broken_links</span> = {}

  <span class="ruby-identifier">definition</span>.<span class="ruby-identifier">specs</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">spec</span><span class="ruby-operator">|</span>
    <span class="ruby-identifier">bundles_for_gem</span>(<span class="ruby-identifier">spec</span>).<span class="ruby-identifier">each</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">bundle</span><span class="ruby-operator">|</span>
      <span class="ruby-identifier">bad_paths</span> = <span class="ruby-identifier">dylibs</span>(<span class="ruby-identifier">bundle</span>).<span class="ruby-identifier">select</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span>
        <span class="ruby-constant">Fiddle</span>.<span class="ruby-identifier">dlopen</span>(<span class="ruby-identifier">f</span>)
        <span class="ruby-keyword">false</span>
      <span class="ruby-keyword">rescue</span> <span class="ruby-constant">Fiddle</span><span class="ruby-operator">::</span><span class="ruby-constant">DLError</span>
        <span class="ruby-keyword">true</span>
      <span class="ruby-keyword">end</span>
      <span class="ruby-keyword">if</span> <span class="ruby-identifier">bad_paths</span>.<span class="ruby-identifier">any?</span>
        <span class="ruby-identifier">broken_links</span>[<span class="ruby-identifier">spec</span>] <span class="ruby-operator">||=</span> []
        <span class="ruby-identifier">broken_links</span>[<span class="ruby-identifier">spec</span>].<span class="ruby-identifier">concat</span>(<span class="ruby-identifier">bad_paths</span>)
      <span class="ruby-keyword">end</span>
    <span class="ruby-keyword">end</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">permissions_valid</span> = <span class="ruby-identifier">check_home_permissions</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">broken_links</span>.<span class="ruby-identifier">any?</span>
    <span class="ruby-identifier">message</span> = <span class="ruby-string">&quot;The following gems are missing OS dependencies:&quot;</span>
    <span class="ruby-identifier">broken_links</span>.<span class="ruby-identifier">map</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">spec</span>, <span class="ruby-identifier">paths</span><span class="ruby-operator">|</span>
      <span class="ruby-identifier">paths</span>.<span class="ruby-identifier">uniq</span>.<span class="ruby-identifier">map</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">path</span><span class="ruby-operator">|</span>
        <span class="ruby-node">&quot;\n * #{spec.name}: #{path}&quot;</span>
      <span class="ruby-keyword">end</span>
    <span class="ruby-keyword">end</span>.<span class="ruby-identifier">flatten</span>.<span class="ruby-identifier">sort</span>.<span class="ruby-identifier">each</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">m</span><span class="ruby-operator">|</span> <span class="ruby-identifier">message</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">m</span> }
    <span class="ruby-identifier">raise</span> <span class="ruby-constant">ProductionError</span>, <span class="ruby-identifier">message</span>
  <span class="ruby-keyword">elsif</span> <span class="ruby-operator">!</span><span class="ruby-identifier">permissions_valid</span>
    <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">ui</span>.<span class="ruby-identifier">info</span> <span class="ruby-string">&quot;No issues found with the installed bundle&quot;</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                          </section>

                <section id="private-instance-5Buntitled-5D-method-details" class="method-section">
                <header>
                <h3>Private Instance Methods</h3>
                </header>

                  <div id="method-i-check_home_permissions" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">check_home_permissions</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="check_home_permissions-source">
            <pre><span class="ruby-comment"># File bundler/cli/doctor.rb, line 105</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">check_home_permissions</span>
  <span class="ruby-identifier">require</span> <span class="ruby-string">&quot;find&quot;</span>
  <span class="ruby-identifier">files_not_readable_or_writable</span> = []
  <span class="ruby-identifier">files_not_rw_and_owned_by_different_user</span> = []
  <span class="ruby-identifier">files_not_owned_by_current_user_but_still_rw</span> = []
  <span class="ruby-identifier">broken_symlinks</span> = []
  <span class="ruby-constant">Find</span>.<span class="ruby-identifier">find</span>(<span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">bundle_path</span>.<span class="ruby-identifier">to_s</span>).<span class="ruby-identifier">each</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span>
    <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-identifier">f</span>)
      <span class="ruby-identifier">broken_symlinks</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">f</span>
    <span class="ruby-keyword">elsif</span> <span class="ruby-operator">!</span><span class="ruby-constant">File</span>.<span class="ruby-identifier">writable?</span>(<span class="ruby-identifier">f</span>) <span class="ruby-operator">||</span> <span class="ruby-operator">!</span><span class="ruby-constant">File</span>.<span class="ruby-identifier">readable?</span>(<span class="ruby-identifier">f</span>)
      <span class="ruby-keyword">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">stat</span>(<span class="ruby-identifier">f</span>).<span class="ruby-identifier">uid</span> <span class="ruby-operator">!=</span> <span class="ruby-constant">Process</span>.<span class="ruby-identifier">uid</span>
        <span class="ruby-identifier">files_not_rw_and_owned_by_different_user</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">f</span>
      <span class="ruby-keyword">else</span>
        <span class="ruby-identifier">files_not_readable_or_writable</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">f</span>
      <span class="ruby-keyword">end</span>
    <span class="ruby-keyword">elsif</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">stat</span>(<span class="ruby-identifier">f</span>).<span class="ruby-identifier">uid</span> <span class="ruby-operator">!=</span> <span class="ruby-constant">Process</span>.<span class="ruby-identifier">uid</span>
      <span class="ruby-identifier">files_not_owned_by_current_user_but_still_rw</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">f</span>
    <span class="ruby-keyword">end</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">ok</span> = <span class="ruby-keyword">true</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">broken_symlinks</span>.<span class="ruby-identifier">any?</span>
    <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">ui</span>.<span class="ruby-identifier">warn</span> <span class="ruby-node">&quot;Broken links exist in the Bundler home. Please report them to the offending gem&#39;s upstream repo. These files are:\n - #{broken_symlinks.join(&quot;\n - &quot;)}&quot;</span>

    <span class="ruby-identifier">ok</span> = <span class="ruby-keyword">false</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">files_not_owned_by_current_user_but_still_rw</span>.<span class="ruby-identifier">any?</span>
    <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">ui</span>.<span class="ruby-identifier">warn</span> <span class="ruby-string">&quot;Files exist in the Bundler home that are owned by another &quot;</span> \
      <span class="ruby-node">&quot;user, but are still readable/writable. These files are:\n - #{files_not_owned_by_current_user_but_still_rw.join(&quot;\n - &quot;)}&quot;</span>

    <span class="ruby-identifier">ok</span> = <span class="ruby-keyword">false</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">files_not_rw_and_owned_by_different_user</span>.<span class="ruby-identifier">any?</span>
    <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">ui</span>.<span class="ruby-identifier">warn</span> <span class="ruby-string">&quot;Files exist in the Bundler home that are owned by another &quot;</span> \
      <span class="ruby-node">&quot;user, and are not readable/writable. These files are:\n - #{files_not_rw_and_owned_by_different_user.join(&quot;\n - &quot;)}&quot;</span>

    <span class="ruby-identifier">ok</span> = <span class="ruby-keyword">false</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">files_not_readable_or_writable</span>.<span class="ruby-identifier">any?</span>
    <span class="ruby-constant">Bundler</span>.<span class="ruby-identifier">ui</span>.<span class="ruby-identifier">warn</span> <span class="ruby-string">&quot;Files exist in the Bundler home that are not &quot;</span> \
      <span class="ruby-node">&quot;readable/writable by the current user. These files are:\n - #{files_not_readable_or_writable.join(&quot;\n - &quot;)}&quot;</span>

    <span class="ruby-identifier">ok</span> = <span class="ruby-keyword">false</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">ok</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                          </section>

              </section>
              </main>



            </div>  <!--  class='wrapper hdiv' -->


<footer id="validator-badges" role="contentinfo">
<p><a href="https://validator.w3.org/check/referer">Validate</a></p>
<p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.4.0.</p>
<p>Based on <a href="https://github.com/ged/darkfish/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.</p>

  
    <p><p><a href="https://ruby-doc.org">Ruby-doc.org</a> is provided by <a href="https://jamesbritt.com">James Britt</a> and <a href="https://neurogami.com">Neurogami</a>.</p><p><a href="https://jamesbritt.bandcamp.com/">Maximum R+D</a>.  </p>
</p>
  
  </footer>

<script type="text/javascript">


  let ads  = $("#carbonads-container").children().detach();


  function swapMode() {
    var cookieName = 'darkmode';
    var cssDarkmode = Cookies.get(cookieName);
    console.log("***** swapMode! " + cssDarkmode + " *****");


    if (cssDarkmode == "true") {
      console.log("We have dark mode, set the css to light ...");
      $('#rdoccss').attr("href", defaultModeCssHref);
      $('#cssSelect').text("Dark mode");
      cssDarkmode = "false";
      console.log("swapMode! Now set cookie to " + cssDarkmode);
      Cookies.set(cookieName, cssDarkmode);

    } else {
      console.log("We not have dark mode, set the css to dark ...");
      $('#rdoccss').attr("href", darkModeCsseHref);
      $('#cssSelect').text("Light mode");
      cssDarkmode = "true";
      console.log("swapMode! Now set cookie to " + cssDarkmode);
      Cookies.set(cookieName, cssDarkmode);

    }

    console.log("  --------------- ");
  }


const vueCssApp = new Vue({
el: '#menubar',
data: {
isDark: false
},
methods: {
toggleClass: function(event){
this.isDark = !this.isDark;
}
}
})

const vueApp = new Vue({
el: '#vapp',
data: { 
isOpen: true
},

mounted() {
this.handleResize();
this.manage_mob_classes();
window.addEventListener('resize', this.handleResize)
//this.isOpen !=  (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent));
},
destroyed() {
window.removeEventListener('resize', this.handleResize)
},
created() {
//manage_mob_classes();
},

methods : {
isMobile() {
  return (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent));
},

  handleResize() {
    if (!this.isMobile()) {
      this.isOpen = window.innerWidth > 800;
    }
  },

  manage_mob_classes() {
    if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) {
      $("nav").addClass("mob_nav");
      $("main").addClass("mob_main");
      $("#extraz").addClass("mob_extraz");
      $("#carbonads-container").addClass("mob_carbonads-container");
      this.isOpen  = false;
    } else {
      $("nav").removeClass("mob_nav") 
        $("main").removeClass("mob_main");
      $("#extraz").removeClass("mob_extraz");
      $("#carbonads-container").removeClass("mob_carbonads-container");
      this.isOpen  = true;
    }
  },

  toggleNav() {
    this.isOpen =! this.isOpen ;
    // alert("Toggle nav!");
    console.log("toggleNav() click: " + this.isOpen );
  }
}
})

$("#carbonads-container").append(ads);


$(function() {

    var darkmode = Cookies.get("darkmode");
    console.log("Document ready: " + darkmode);

    if ( darkmode  == "true" ) {
      $('#cssSelect').text("Light mode");
    } else {
      $('#cssSelect').text("Dark mode");
     }

    $('body').css('display','block');
    });

</script>

    
  </body> 
</html>

